package com.xinpujing.caiji.job;

import com.xinpujing.caiji.enums.LotteryTypeEnum;
import com.xinpujing.caiji.service.Api68Service;
import com.xinpujing.caiji.service.ApiLotteryService;
import com.xinpujing.caiji.service.OpenCaiService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Component;

/**
 * 采集任务
 */
public class CaijiJob {
    private OpenCaiService openCaiService;

    private Api68Service api68Service;

    private ApiLotteryService apiLotteryService;

    //opencai.com 的token
    public String openCaiToken = "";

    /**
     * 六合彩
     */
    public void lhc() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/xj6hc",LotteryTypeEnum.LHC);
    }

    /**
     * （福彩）福彩3D
     */
    public void fc3d() {
        openCaiService.insertIfNotExist(this.openCaiToken , LotteryTypeEnum.FC3D);
    }

    /**
     * 排列3
     */
    public void pl3() {
        api68Service.insertIfNotExist("http://api.api68.com/QuanGuoCai/getLotteryInfo1.do?issue=&lotCode=10043" , LotteryTypeEnum.PL3);
    }

    /**
     * PC蛋蛋
     */
    public void pcdd() {
        api68Service.insertIfNotExist("http://api.api68.com/LuckTwenty/getPcLucky28.do?&lotCode=" , LotteryTypeEnum.PCDD);
    }

    /**
     * 广东快乐十分
     */
    public void gdklsf() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/gdkl10f",LotteryTypeEnum.GDKLSF);
    }

    /**
     * 北京快乐8
     */
    public void bjkl8() {
        api68Service.insertIfNotExist("http://api.api68.com/LuckTwenty/getBaseLuckTewnty.do?issue=&lotCode=10014" , LotteryTypeEnum.BJKL8);
    }

    /**
     * 重庆幸运农场
     */
    public void cqxync() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/xylc",LotteryTypeEnum.CQXYNC);
    }

    /**
     * 广西快乐十分
     */
    public void gxklsf() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/gxkl10f" , LotteryTypeEnum.GXKLSF);
    }

    /**
     * 新疆时时彩
     */
    public void xjssc() {
        api68Service.insertIfNotExist("http://api.api68.com/CQShiCai/getBaseCQShiCai.do?lotCode=10004" , LotteryTypeEnum.XJSSC);
    }

    /**
     * 天津时时彩
     */
    public void tjssc() {
        api68Service.insertIfNotExist("http://api.api68.com/CQShiCai/getBaseCQShiCai.do?lotCode=10003" , LotteryTypeEnum.TJSSC);
    }

    /**
     * 重庆时时彩
     */
    public void cqssc() {
        api68Service.insertIfNotExist("http://api.api68.com/CQShiCai/getBaseCQShiCai.do?lotCode=10002" , LotteryTypeEnum.CQSSC);
    }

    /**
     * 江西时时彩
     */
    public void jxssc() {
        api68Service.insertIfNotExist("" , LotteryTypeEnum.JXSSC);
    }

    /**
     * 腾讯分分彩
     */
    public void txffc() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/txffc2" , LotteryTypeEnum.TXFFC);
    }

    /**
     * 北京时时彩
     */
    public void bjssc() {
        api68Service.insertIfNotExist("" , LotteryTypeEnum.BJSSC);
    }

    /**
     * 北京pk10
     */
    public void bjkc() {
        api68Service.insertIfNotExist("http://api.api68.com/pks/getLotteryPksInfo.do?issue=&lotCode=10001" , LotteryTypeEnum.BJKC);
    }

    /**
     * 幸运飞艇
     */
    public void xyft() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/xyft" , LotteryTypeEnum.XYFT);
    }

    /**
     * 江苏快3
     */
    public void jsk3() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10007" , LotteryTypeEnum.JSK3);
    }

    /**
     * 广西快3
     */
    public void gxk3() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10026" , LotteryTypeEnum.GXK3);
    }

    /**
     * 河北快3
     */
    public void hbk3() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/hebk3" , LotteryTypeEnum.HBK3);
    }

    /**
     *吉林快3
     */
    public void jlks() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10027" , LotteryTypeEnum.JLKS);
    }

    /**
     * 湖北快3
     */
    public void hubks() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10032" , LotteryTypeEnum.HUBKS);
    }

    /**
     * 安徽快三
     */
    public void ahks() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/ahk3" , LotteryTypeEnum.AHKS);
    }

    /**
     *贵州快三
     */
    public void gzks() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/guizk3" , LotteryTypeEnum.GZKS);
    }

    /**
     *湖南快3
     */
    public void hnks() {
        api68Service.insertIfNotExist("" , LotteryTypeEnum.HNKS);;
    }

    /**
     * 上海快3
     */
    public void shks() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/shk3" , LotteryTypeEnum.SHKS);;
    }

    /**
     * 甘肃快3
     */
    public void gsks() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/gsk3" , LotteryTypeEnum.GSKS);;
    }

    /**
     * 北京快3
     */
    public void bjks() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10033" , LotteryTypeEnum.BJKS);
    }

    /**
     * 福建快3
     */
    public void fjks() {
        api68Service.insertIfNotExist("http://api.api68.com/lotteryJSFastThree/getBaseJSFastThree.do?lotCode=10031" , LotteryTypeEnum.FJKS);
    }

    /**
     * 广东11选5
     */
    public void gd11x5() {
        api68Service.insertIfNotExist("http://api.api68.com/ElevenFive/getElevenFiveInfo.do?lotCode=10006" , LotteryTypeEnum.GD11X5);
    }

    /**
     * 江西11选5
     */
    public void jx11x5() {
        api68Service.insertIfNotExist("http://api.api68.com/ElevenFive/getElevenFiveInfo.do?lotCode=10015" , LotteryTypeEnum.JX11X5);
    }

    /**
     * 江苏11选5
     */
    public void js11x5() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/js11x5" , LotteryTypeEnum.JS11X5);
    }

    /**
     * 黑龙江11选5
     */
    public void hlj11x5() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/hlj11x5" , LotteryTypeEnum.HLJ11X5);
    }

    /**
     * 新疆11选5
     */
    public void xj11x5() {
        apiLotteryService.insertIfNotExist("http://free.apilottery.cn/xj11x5" , LotteryTypeEnum.XJ11X5);
    }

    /**
     * 上海11选5
     */
    public void sh11x5() {
        api68Service.insertIfNotExist("http://api.api68.com/ElevenFive/getElevenFiveInfo.do?lotCode=10018" , LotteryTypeEnum.SH11X5);
    }

    public OpenCaiService getOpenCaiService() {
        return openCaiService;
    }

    public void setOpenCaiService(OpenCaiService openCaiService) {
        this.openCaiService = openCaiService;
    }

    public Api68Service getApi68Service() {
        return api68Service;
    }

    public void setApi68Service(Api68Service api68Service) {
        this.api68Service = api68Service;
    }

    public String getOpenCaiToken() {
        return openCaiToken;
    }

    public void setOpenCaiToken(String openCaiToken) {
        this.openCaiToken = openCaiToken;
    }

    public ApiLotteryService getApiLotteryService() {
        return apiLotteryService;
    }

    public void setApiLotteryService(ApiLotteryService apiLotteryService) {
        this.apiLotteryService = apiLotteryService;
    }
}
